1. Field of the Invention
The present invention relates generally to three-dimensional (3D) rendering of a scene, and in particular, to a method, apparatus, and article of manufacture for illuminating and creating shadows based on external light sources present in a user's physical environment.
2. Description of the Related Art
Stereoscopy is a method for presenting an illusion of 3D depth from images on a two-dimensional (2D) plane. To create such an illusion, two slightly offset images are presented separately to the left and right eye of a viewer. Various techniques may be used to mechanically present the 3D illusion to a user. Some stereoscopic techniques may require a viewer to wear glasses that combine the images from two offset sources and/or to filter offset images from a single source separated to each eye. Alternatively, in a technique known as autostereoscopy, a lightsource may split the images directionally into the viewer's eyes (without requiring glasses).
Regardless of the technique used to provide stereoscopy, a 3D rendering of a scene (stereoscopic or non-stereoscopic) will not give depth perception if there are no shadows associated with the objects that are being rendered. The human brain analyzes the shadows cast by the objects due to ambient light conditions for depth perception. For example, a 3D render of a ball bouncing on a flat surface without the associated shadows does not convey the correct sense of depth as well as motion to the user. Similarly, a monster character coming out of a screen in a stereoscopic game would give a more accurate impression of depth to a user only when it projects associated shadows.
FIG. 1 illustrates the shadow rendering of the prior art. A 3D scene 102 is displayed within a stereoscopic 3D display 104. A light source 106 present within scene 102 casts a shadow 108. Since the scene 102 is stereoscopic, it is desirable for external light 110 to affect the shadows. However, as illustrated in FIG. 1, in the prior art, such external light sources 110 do not affect the shadow 108 or view of the scene 102.
Furthermore, it is desirable to render a very realistic scene that blends in with the surroundings of the display system. Such a rendering is possible if the illumination and shadows in the scene are cast based on the ambient light sources present in a user's physical environment. The prior art fails to provide such a capability.